<div id="content">
	<div id="title"><h1><?php echo $title; ?></h1></div>

	<div id = "wrap-table">
		<?php
		if(empty($row->advertisementsid)){
			echo form_open_multipart('admin/advertisements/save');
		}
		else{
			echo form_open_multipart('admin/advertisements/update/'.$this->uri->segment(4));
		}
		?>
		<table border="1" class="admin-tableform">
			<tbody>
				<?php if(!empty($row->banner)) :?>
				<tr>
					<td colspan = "2"><img src = "<?php echo base_url().'assets/images'.$row->banner; ?>" /></td>
				</tr>
				<?php endif; ?>
				<tr>
					<td class='key'>Banner</td><td><input type="file" name="banner" id = "banner_pic" size="20" value = "" /></td>
				</tr>
				<tr>
					<td>Name</td><td><input type="text" name="name" value="<?php echo @$row->name; ?>" /></td>
				</tr>
				<tr>
					<td>Section</td><td>
					<?php $this->load->helper('Select_helper');
					echo section('section', '', @$row->section); ?>
					</td>
				</tr>
				<tr>
					<td>Publish</td>
					<td>
					<?php
						echo Boolean_helper::yesno('', @$row->status); ?>
					</td>
				</tr>
				<tr>
					<td colspan = "2">
					<input id = "ads_sumbit" type = "submit" name = "" value = "Save" />
					<input id = "ads_clear" type = "reset" name = "" value = "Cancel" />
					</td>
				</tr>
			</tbody>
		</table>
	</div>
	</form>
</div>